package com.example.mapper;

import com.example.entity.Category;
import org.apache.ibatis.annotations.Delete;
import org.apache.ibatis.annotations.Mapper;

import java.util.List;

/**
 * @author: 康伟奇
 * @date: 2023 - 11 - 11 00:29
 **/
@Mapper
public interface CategoryMapper {
    void deleteById(Integer id);

    List<Category> selectAll(Category category);

    Category selectById(Integer id);

    void insert(Category category);

    void updateById(Category category);

    @Delete("delete from category where business_id = #{businessId}")
    void deleteByBusinessId(Integer businessId);
}
